//
//  SecondTableViewCell.m
//  A段
//
//  Created by 潘君峰 on 15/4/10.
//  Copyright (c) 2015年 dllo. All rights reserved.
//

#import "SecondTableViewCell.h"

@implementation SecondTableViewCell
- (void)dealloc
{
    [_backView release];
    [_watchPhoto release];
    [_titleLabel release];
    [_pubdateLabel release];
    [_summaryLabel release];
    [super dealloc];
}
- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        self.backView = [[[UIView alloc] initWithFrame:CGRectMake(0, 10, 375, 140)]autorelease];
//        [self.backView setBackgroundColor:[UIColor yellowColor]];
        //圆角设置
//        self.backView.layer.cornerRadius = 30;
        [self addSubview:self.backView];
        self.watchPhoto = [[[UIImageView alloc] initWithFrame:CGRectMake(5, 10, 140, 120)]autorelease];
        self.watchPhoto.layer.cornerRadius = 20;
        [self.backView addSubview:self.watchPhoto];
        self.titleLabel = [[[UILabel alloc] initWithFrame:CGRectMake(150, 20, 200, 20)]autorelease];
        self.titleLabel.font = [UIFont boldSystemFontOfSize:18.0];
        [self addSubview:self.titleLabel];
        self.pubdateLabel = [[[UILabel alloc]initWithFrame:CGRectMake(150, 35, 200, 20)]autorelease];
        self.pubdateLabel.textColor = [UIColor colorWithRed:0.8 green:0.8 blue:0.8 alpha:1.0];
        self.pubdateLabel.font = [UIFont systemFontOfSize:14.0];
        //系统
//        self.pubdateLabel.font = [UIFont systemFontOfSize:<#(CGFloat)#>]
        //粗体
//        self.pubdateLabel.font = [UIFont boldSystemFontOfSize:  italicSystemFontOfSize:<#(CGFloat)#>:<#(CGFloat)#>]
        //对齐方式
//        self.pubdateLabel.textAlignment = NSTextAlignmentLeft
        [self.backView addSubview:self.pubdateLabel];
        self.summaryLabel = [[[UILabel alloc] initWithFrame:CGRectMake(150, 50, 200, 60)]autorelease];
        self.summaryLabel.font = [UIFont systemFontOfSize:15.0];
        [self.backView addSubview:self.summaryLabel];
    }
    return self;
}

- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
